<template>
	<view>
		<view class="box">
			<image class="image" :src="imgUrl" ></image>
			<view class="btn-box">
				<button v-if="!noShow" class="save" @click="autographClick">重新签名</button>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				imgUrl: '',
				noShow: false
			}
		},
		onLoad(options) {
			console.log(JSON.parse(decodeURIComponent(options.url)))
			this.imgUrl = JSON.parse(decodeURIComponent(options.url))
			this.noShow = options.noShow
		},
		methods: {
			autographClick() {
				uni.navigateTo({
					url: '/pages/subPackagesD/mycenter/signname'
				})
			}
		}
	}
</script>

<style lang="scss">
	.box {
		// padding: 30rpx;
		width: 92vw;
		height: 40vh;
		position: relative;
		display: block;
		overflow: hidden;
		margin-top: 25vh;

		.image {
			position: absolute;
			top: 50%;
			left: 50%;
			display: block;
			transform: translate(-50%, -50%);
			height: 100%;
		}
		.btn-box{
			width: 100vw;
			position: fixed;
			bottom: 48rpx;
			display: flex;
			align-items: center;
			justify-content: center;
			
			button {
				width: 100%;
				margin: 0 32rpx;
				display: flex;
				justify-content: center;
				align-items: center;
				border: 1px solid #0F53AC;
				border-radius: 6px;
				font-size: 34rpx;
				font-weight: 400;
			}
			
			button::after {
				border: none;
			}
		}
		

		.save {
			color: #0F53AC;
			background-color: #fff;
			font-size: 34rpx;
			font-weight: 400;
		}
	}
</style>
